package cn.bigcontainer.alt.workflow.util;

import java.util.List;

public class WorkflowUtil {

    public static String getProperties (List<String> props, String taskName) {
        String s = "";
        for (String format : props) {
            s += String.format(format, taskName) + ";";
        }
        return s.substring(0, s.length() - 1);
    }

    public static String getDefaultProperties (String taskName) {
        return getProperties(WorkflowConstant.PROPS_FORMAT, taskName);
    }

    public static String getReviewProperties (String taskName) {
        return getProperties(WorkflowConstant.PROPS_REVIEW_FORMAT, taskName);
    }
}
